const app = getApp()
const $api = require('../../utils/api.js').API;
Page({
    data: {
        list:{},
        content:'积分商城正在筹备中，具体时间可留意平台动态。',
        contentShow:false,
        item:{}
    },
    onLoad: function(){
        this.getList();
    },
    getList:function(){
        var that = this;
        var data = {}
        $api.get('problem/list',data).then(res => {
        //请求成功
        if(res.data.code == 1){
            that.setData({
                list:res.data.data
            })
        }
    }).catch(err => {
        //请求失败
        //console.log('error','请求失败');
    })
    },
    showcontent:function(e){
        this.setData({
            contentShow:true,
            item:e.currentTarget.dataset.item
        })
    },
    close:function(){
        this.setData({
            contentShow:false
        })
    },
    robot:function(){
        wx.navigateTo({
            url:'/pages/customer/robot/index'
        })
    },
    onShareAppMessage: function() {
        return {
            title: "天意美业直通车",
            path: "/pages/index/index?puid="+wx.getStorageSync('uid')
        };
      }
});